class Person {
  constructor (sex = 'male', age = '26') {
    this.sex = sex
    this.age = age
  }
  // 设置一个静态方法
  static getName() {
    return 'lee'
  }
  getInfo() {
    return this.sex + ', ' + this.age
  }
}

class Student extends Person {
  constructor (sex, age, name) {
    super(sex, age)
    this.name = name
  }
  print() {
    var info = this.getInfo()
    console.log(info)
  }
}
var st1 = new Student('male', 'lican')
st1.print() // male, lican